3.11 \(\int \frac {\cos (x) \sin (x)}{x^2} \, dx\)

Optimal. Leaf size=16 \[ \text {Ci}(2 x)-\frac {\sin (2 x)}{2 x} \]

[Out]

Ci(2*x)-1/2*sin(2*x)/x

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 16, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.500, Rules used = {4406, 12, 3297, 3302} \[ \text {CosIntegral}(2 x)-\frac {\sin (2 x)}{2 x} \]

Antiderivative was successfully verified.

[In]

Int[(Cos[x]*Sin[x])/x^2,x]

[Out]

CosIntegral[2*x] - Sin[2*x]/(2*x)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 3297

Int[((c_.) + (d_.)*(x_))^(m_)*sin[(e_.) + (f_.)*(x_)], x_Symbol] :> Simp[((c + d*x)^(m + 1)*Sin[e + f*x])/(d*(
m + 1)), x] - Dist[f/(d*(m + 1)), Int[(c + d*x)^(m + 1)*Cos[e + f*x], x], x] /; FreeQ[{c, d, e, f}, x] && LtQ[
m, -1]

Rule 3302

Int[sin[(e_.) + (f_.)*(x_)]/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[CosIntegral[e - Pi/2 + f*x]/d, x] /; FreeQ
[{c, d, e, f}, x] && EqQ[d*(e - Pi/2) - c*f, 0]

Rule 4406

Int[Cos[(a_.) + (b_.)*(x_)]^(p_.)*((c_.) + (d_.)*(x_))^(m_.)*Sin[(a_.) + (b_.)*(x_)]^(n_.), x_Symbol] :> Int[E
xpandTrigReduce[(c + d*x)^m, Sin[a + b*x]^n*Cos[a + b*x]^p, x], x] /; FreeQ[{a, b, c, d, m}, x] && IGtQ[n, 0]
&& IGtQ[p, 0]

Rubi steps

\begin {align*} \int \frac {\cos (x) \sin (x)}{x^2} \, dx &=\int \frac {\sin (2 x)}{2 x^2} \, dx\\ &=\frac {1}{2} \int \frac {\sin (2 x)}{x^2} \, dx\\ &=-\frac {\sin (2 x)}{2 x}+\int \frac {\cos (2 x)}{x} \, dx\\ &=\text {Ci}(2 x)-\frac {\sin (2 x)}{2 x}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 16, normalized size = 1.00 \[ \text {Ci}(2 x)-\frac {\sin (2 x)}{2 x} \]

Antiderivative was successfully verified.

[In]

Integrate[(Cos[x]*Sin[x])/x^2,x]

[Out]

CosIntegral[2*x] - Sin[2*x]/(2*x)

________________________________________________________________________________________

fricas [A]  time = 0.76, size = 24, normalized size = 1.50 \[ \frac {x \operatorname {Ci}\left (2 \, x\right ) + x \operatorname {Ci}\left (-2 \, x\right ) - 2 \, \cos \relax (x) \sin \relax (x)}{2 \, x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="fricas")

[Out]

1/2*(x*cos_integral(2*x) + x*cos_integral(-2*x) - 2*cos(x)*sin(x))/x

________________________________________________________________________________________

giac [A]  time = 0.14, size = 19, normalized size = 1.19 \[ \frac {2 \, x \operatorname {Ci}\left (2 \, x\right ) - \sin \left (2 \, x\right )}{2 \, x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="giac")

[Out]

1/2*(2*x*cos_integral(2*x) - sin(2*x))/x

________________________________________________________________________________________

maple [A]  time = 0.02, size = 15, normalized size = 0.94 \[ \Ci \left (2 x \right )-\frac {\sin \left (2 x \right )}{2 x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(x)*sin(x)/x^2,x)

[Out]

Ci(2*x)-1/2*sin(2*x)/x

________________________________________________________________________________________

maxima [C]  time = 0.38, size = 15, normalized size = 0.94 \[ \frac {1}{2} \, \Gamma \left (-1, 2 i \, x\right ) + \frac {1}{2} \, \Gamma \left (-1, -2 i \, x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x^2,x, algorithm="maxima")

[Out]

1/2*gamma(-1, 2*I*x) + 1/2*gamma(-1, -2*I*x)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.06 \[ \int \frac {\cos \relax (x)\,\sin \relax (x)}{x^2} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((cos(x)*sin(x))/x^2,x)

[Out]

int((cos(x)*sin(x))/x^2, x)

________________________________________________________________________________________

sympy [A]  time = 1.57, size = 22, normalized size = 1.38 \[ - \log {\relax (x )} + \frac {\log {\left (x^{2} \right )}}{2} + \operatorname {Ci}{\left (2 x \right )} - \frac {\sin {\left (2 x \right )}}{2 x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(x)*sin(x)/x**2,x)

[Out]

-log(x) + log(x**2)/2 + Ci(2*x) - sin(2*x)/(2*x)

________________________________________________________________________________________